package cn.bdqn.config;

import cn.bdqn.web.filter.AuthorizationFilter;
import org.springframework.boot.web.servlet.FilterRegistrationBean;

//@Configuration
public class FilterConfig {
//    @Bean
    public FilterRegistrationBean filterRegistrationBean(){
        FilterRegistrationBean registrationBean=new FilterRegistrationBean();
        registrationBean.setFilter(new AuthorizationFilter());
        registrationBean.setName("AuthorizationFilter");
        registrationBean.addUrlPatterns("/main");
        registrationBean.setOrder(5);
        return registrationBean;
    }
}
